import SwiftUI
import Combine

enum TabBarItem: Int {
   case Home
   case Living
   case Message
   case Mine
   
   var titleStr: String {
       switch self {
       case .Home:
           return "首页"
       case .Living:
           return "直播"
       case .Message:
           return "消息"
       case .Mine:
           return "我的"
       }
   }
   
   var normalImage: Image {
       var imageName = ""
       switch self {
       case .Home:
           imageName = ""
       case .Living:
           imageName = ""
       case .Message:
           imageName = ""
       case .Mine:
           imageName = ""
       }
       return Image(imageName)
   }
   
   var selectedImage: Image {
       var imageName = ""
       switch self {
       case .Home:
           imageName = ""
       case .Living:
           imageName = ""
       case .Message:
           imageName = ""
       case .Mine:
           imageName = ""
       }
       return Image(imageName)
   }
}

final class TabBarIndexObserver: ObservableObject {
   @Published
   var tabSelected: TabBarItem = .Home
}
